<template>
  <div>
    <div class="comp-mointor-device-info">
      <div class="comp-mointor-device-info-header" v-if="title != null">
        <img src="@/assets/cloudV2/img/title.png" alt="">
        <span>{{ title }}</span>
      </div>

      <slot/>

      <img class="left-top" src="@/assets/cloudV2/img/top-left.png" alt="">
      <img class="right-top" src="@/assets/cloudV2/img/top-left.png" alt="">
      <img class="right-bottom" src="@/assets/cloudV2/img/top-left.png" alt="">
      <img class="left-bottom" src="@/assets/cloudV2/img/top-left.png" alt="">
    </div>
  </div>
</template>

<script setup>

defineProps({
  title: String
})

</script>

<style scoped>
.comp-mointor-device-info {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: space-between;
  background: url("@/assets/cloudV2/img/monitor-box-slide-pie-new.png") no-repeat 0 0;
  background-size: 100% 100%;
}

.easy-scrollbar {
  width: 45%;
  height: 100%;
  padding-top: 26px;
}

.easy-scrollbar__wrap {
  height: 100%;

  overflow-y: scroll !important;
  overflow-x: hidden !important;
}

.esay-scrollbar__bar.is-vertical {
  top: 38px;
}

.warning-info {
  padding-top: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
}

.warning-num {
  color: #32EBCA;
  margin-bottom: 6px;
  font-weight: normal;
}

.warning-num-each {
  display: flex;
}

.warning-num-each-bg {
  margin-right: 4px;
  width: 20px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: url("@/assets/cloudV2/img/num-bg.png") no-repeat 50% 0;
}

.left-top {
  position: absolute;
  width: 5%;
  top: 0;
  left: 0;
}

.right-top {
  position: absolute;
  width: 5%;
  top: 0;
  right: 0;
  transform: rotate(90deg)
}

.right-bottom {
  position: absolute;
  width: 5%;
  bottom: 0;
  right: 0;
  transform: rotate(180deg)
}

.left-bottom {
  position: absolute;
  width: 5%;
  bottom: 0;
  left: 0;
  transform: rotate(-90deg)
}

.comp-mointor-device-info-header {
  color: #ffffff;
  position: absolute;
  top: 8px;
  left: 14px;
  display: flex;
  align-items: center;

}

.comp-mointor-device-info-header span {
  font-size: 14px;
  display: inline-block;
  margin-left: 8px;
}

.comp-mointor-device-info-num {
  color: #34ECCB;
  padding-top: 26px;
  padding-bottom: 12px;
  width: 45%;
  height: 100%;
  background-size: 100% 100%;
}

.comp-mointor-device-info-pie {
  width: 55%;
  height: 100%;
  /*border: 1px solid pink;*/
  /*border-radius: 50%;*/
  background-size: 100% 100%;
}
</style>